package com.webull.information.center.carwler.common.model;

import java.util.Date;

/**
 * 新闻源检测model集合
 * 
 * @author shimingjun
 * @date 2017年2月17日 下午4:52:26
 * @version 1.0
 * @since JDK 1.8
 */
public class NewsDetection {
	public static class Detection {
		private Integer tickerId;// ` int(11) NOT NULL ,
		private String sExchange;// ` varchar(50) NOT NULL ,
		private String sSymbol;// ` varchar(50) NOT NULL,
		private String sSource;// ` varchar(50) NOT NULL,
		private Date createTime;// ` timestamp NOT NULL DEFAULT
								// CURRENT_TIMESTAMP COMMENT '创建时间',
		private Date updateTime;// ` timestamp NOT NULL DEFAULT
								// CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
								// COMMENT '修改时间',
		private Boolean del;// ` tinyint(2) NOT NULL DEFAULT '0' COMMENT
							// '1:已删，0:正常，Java:boolean',

		public Integer getTickerId() {
			return tickerId;
		}

		public void setTickerId(Integer tickerId) {
			this.tickerId = tickerId;
		}

		public String getsExchange() {
			return sExchange;
		}

		public void setsExchange(String sExchange) {
			this.sExchange = sExchange;
		}

		public String getsSymbol() {
			return sSymbol;
		}

		public void setsSymbol(String sSymbol) {
			this.sSymbol = sSymbol;
		}

		public String getsSource() {
			return sSource;
		}

		public void setsSource(String sSource) {
			this.sSource = sSource;
		}

		public Date getCreateTime() {
			return createTime;
		}

		public void setCreateTime(Date createTime) {
			this.createTime = createTime;
		}

		public Date getUpdateTime() {
			return updateTime;
		}

		public void setUpdateTime(Date updateTime) {
			this.updateTime = updateTime;
		}

		public Boolean getDel() {
			return del;
		}

		public void setDel(Boolean del) {
			this.del = del;
		}

		@Override
		public String toString() {
			return "Detection{" +
					"tickerId=" + tickerId +
					", sExchange='" + sExchange + '\'' +
					", sSymbol='" + sSymbol + '\'' +
					", sSource='" + sSource + '\'' +
					'}';
		}
	}

	public static class DetectionResult {
		private Integer tickerId;// ` int(11) NOT NULL ,
		private String sSource;// ` varchar(50) NOT NULL,
		private String title;
		private String url;// ` varchar(200) NOT NULL,
		private String urlMd5;// ` varchar(50) NOT NULL,
		private Date newsTime;// ` timestamp NOT NULL '新闻时间',

		private Date createTime;// ` timestamp NOT NULL DEFAULT
								// CURRENT_TIMESTAMP COMMENT '创建时间',
		private Date updateTime;// ` timestamp NOT NULL DEFAULT
								// CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
								// COMMENT '修改时间',
		private Boolean del;// ` tinyint(2) NOT NULL DEFAULT '0' COMMENT
							// '1:已删，0:正常，Java:boolean',

		public DetectionResult(Detection detection) {
			this.tickerId = detection.getTickerId();
			this.sSource = detection.getsSource();
		}

		public Integer getTickerId() {
			return tickerId;
		}

		public void setTickerId(Integer tickerId) {
			this.tickerId = tickerId;
		}

		public String getsSource() {
			return sSource;
		}

		public void setsSource(String sSource) {
			this.sSource = sSource;
		}

		public String getTitle() {
			return title;
		}

		public void setTitle(String title) {
			this.title = title;
		}

		public String getUrl() {
			return url;
		}

		public void setUrl(String url) {
			this.url = url;
		}

		public String getUrlMd5() {
			return urlMd5;
		}

		public void setUrlMd5(String urlMd5) {
			this.urlMd5 = urlMd5;
		}

		public Date getNewsTime() {
			return newsTime;
		}

		public void setNewsTime(Date newsTime) {
			this.newsTime = newsTime;
		}

		public Date getCreateTime() {
			return createTime;
		}

		public void setCreateTime(Date createTime) {
			this.createTime = createTime;
		}

		public Date getUpdateTime() {
			return updateTime;
		}

		public void setUpdateTime(Date updateTime) {
			this.updateTime = updateTime;
		}

		public Boolean getDel() {
			return del;
		}

		public void setDel(Boolean del) {
			this.del = del;
		}


	}

	public static class Source {
		public static final String RETURE = "retuer";
		public static final String BLOOMB = "bloomb";
		public static final String YAHOO = "yahoo";
		public static final String GOOGLE = "google";
		public static final String INVESTING = "investing";
	}


}
